package com.mt.roll.wms.params;


import com.mt.roll.core.base.BaseParam;
import com.mt.roll.core.validator.groups.UpdateGroup;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * @Author weihongyang
 * @Date 2021/3/10 9:11 上午
 * @Version 1.0
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value = "报废信息参数对象", description = "用于新增和更新报废信息")
public class ScrapInformationParam extends BaseParam {
    private static final long serialVersionUID = 1L;

    /**
     * 主键，自增
     */
    @ApiModelProperty(value = "主键，更新时需要填写", example = "1")
    @NotNull(message = "废品报废ID不能为空", groups = {UpdateGroup.class})
    private Long id;

    /**
     * 报废类型ID
     */
    @ApiModelProperty(value = "报废类型ID", required = true, example = "scrapId")
    @NotNull(message = "报废类型ID不能为空")
    private Long scrapId;

    /**
     * 报废类型
     */
    @ApiModelProperty(value = "报废类型", required = true, example = "scrapType")
    @NotBlank(message = "报废类型不能为空")
    private String scrapType;

    /**
     * 报废原因
     */
    @ApiModelProperty(value = "报废原因", required = true, example = "scrap")
    @NotBlank(message = "报废原因不能为空")
    private String scrap;

    /**
     * 报废编码
     */
    @ApiModelProperty(value = "报废编码", required = true, example = "code")
    @NotBlank(message = "报废编码不能为空")
    private String code;

    /**
     * 备注
     */
    @ApiModelProperty(value = "备注", example = "remark")
    private String remark;
}
